Keycloak REST Services 1.2.0.Final

Path: / admin / realms / {realm} / users / {username} / role-mappings / clients-by-id / {id}

Get client-level role mappings for this user for a specific app

Path parameters:
realm - realm name (not id!)
username -
id -

Sub-Resources
Resources
NameDescription
availableGet available client-level roles that can be mapped to the user
compositeGet effective client-level role mappings.

Resource Methods
Method Summary
NameDescription
GET /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}Get client-level role mappings for this user for a specific app
POST /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}Add client-level roles to the user role mapping.
DELETE /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}Delete client-level roles from user role mapping.

Method Detail

GET /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}

Get client-level role mappings for this user for a specific app

HTTP Example:
GET /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}
API Example:

UserClientRoleMappingsResource.getClientRoleMappings({'realm': /* name realm name (not id!) */,
  'username': …,
  'id': …});

Output:
List<RoleRepresentation> -
Produces:
application/json

POST /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}

Add client-level roles to the user role mapping.

HTTP Example:
POST /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}
API Example:

UserClientRoleMappingsResource.addClientRoleMapping({'realm': /* name realm name (not id!) */,
  'username': …,
  'id': …,
  '$entity': /* roles */});

Input:
List<RoleRepresentation>
Output:
void
Consumes:
application/json

DELETE /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}

Delete client-level roles from user role mapping.

HTTP Example:
DELETE /admin/realms/{realm}/users/{username}/role-mappings/clients-by-id/{id}
API Example:

UserClientRoleMappingsResource.deleteClientRoleMapping({'realm': /* name realm name (not id!) */,
  'username': …,
  'id': …,
  '$entity': /* roles */});

Input:
List<RoleRepresentation>
Output:
void
Consumes:
application/json

Keycloak REST Services 1.2.0.Final